/**
 * 
 */
package metalink;

import vo.LoginInfoVo;
import model.ForgotPasswordMo;

import com.opensymphony.xwork2.ActionSupport;

/**
 * @author Reaper
 *
 */
public class ResetPassword extends ActionSupport{
	String site;
	long cid;
	String password1;
	public String execute()
	{
		ForgotPasswordMo mo=new ForgotPasswordMo();
		LoginInfoVo vo=new LoginInfoVo();
		try {
			vo.setCid(cid);
			vo.setPassword(password1);
			mo.resetPassword(vo, site);
			addActionError("Password Successfully changed..");
			return SUCCESS;
		} catch (Exception e) {
			// TODO Auto-generated catch block
			addActionError("Password Not changed..");
			e.printStackTrace();
			return ERROR;
		}
	}
	
	public String getSite() {
		return site;
	}
	public void setSite(String site) {
		this.site = site;
	}
	public long getCid() {
		return cid;
	}
	public void setCid(long cid) {
		this.cid = cid;
	}
	public String getPassword1() {
		return password1;
	}
	public void setPassword1(String password1) {
		this.password1 = password1;
	}

}
